package com.itheima;

/**
 * 2025/5/15 8:33
 */
public class TestD {
    public static void main(String[] args) {
        D d1 = new D() {
            @Override
            public int max(int a, int b) {
                return a > b ? a : b;
            }
        };

        D d2 = (a, b)-> Math.max(a, b);

        D d3 = Math::max;

        int max = d3.max(10, 20);
        System.out.println(max);
    }
}
